#!/bin/bash

sqoop import \
--connect jdbc:mysql://node101:3306/jtp_app_shujuku \
--driver com.mysql.jdbc.Driver \
--username root \
--password 123456 \
--query 'SELECT * FROM jtp_app_shujuku.t_md_areas WHERE $CONDITIONS;' \
--target-dir hdfs://node101:8020/warehouse/app_basic/t_md_areas \
--fields-terminated-by '\001' \
--delete-target-dir \
--num-mappers 1 \
--null-non-string '\\N' \
--null-string '\\N'